InProc Mode This mode stores the session data in the ASP.NET worker process. This is the fastest among all of the storage modes. This mode effects performance if the amount of data to be stored is large. If ASP.NET worker process recycles or application domain restarts, the session state will be lost.
State Server mode In this mode, the session state is serialized and stored in memory in a separate process. State Server can be maintained on a different system. State Server mode involves overhead since it requires serialization and de-serialization of objects. State Server mode is slower than InProc mode as this stores data in an external process.
SQL Server Mode In this storage mode, the Session data is serialized and stored in a database table in the SQL Server database. This is reliable and secures storage of a session state. This mode can be used in the web farms. It involves overhead in serialization and de-serialization of the objects. SQL Server is more secure than the InProc or the State server mode.
Liked By
Write Answer
What are the Session State Modes? Define each Session State mode supported by ASP.NET.
Join MindStick Community
You have need login or register for voting of answers or question.
Pushpendra Singh
26-Oct-2010ASP.NET supports three Session State modes.
InProc Mode
This mode stores the session data in the ASP.NET worker process.
This is the fastest among all of the storage modes.
This mode effects performance if the amount of data to be stored is large.
If ASP.NET worker process recycles or application domain restarts, the session state will be lost.
State Server mode
In this mode, the session state is serialized and stored in memory in a separate process.
State Server can be maintained on a different system.
State Server mode involves overhead since it requires serialization and de-serialization of objects.
State Server mode is slower than InProc mode as this stores data in an external process.
SQL Server Mode
In this storage mode, the Session data is serialized and stored in a database table in the SQL Server database.
This is reliable and secures storage of a session state.
This mode can be used in the web farms.
It involves overhead in serialization and de-serialization of the objects.
SQL Server is more secure than the InProc or the State server mode.